import { requestClient } from '#/api/request';


// 创建题目
export async function createExamQuestionApi(data: any) {
  return requestClient.post('/certification/create-exam-questions', data);
}

//查询
export async function getExamQuestionsApi(params: any) {
  return requestClient.get('/certification/get-exam-questions', { params });
}

//删除
export async function delExamQuestionsApi(data: any) {
  return requestClient.patch(`/certification/update-exam-questions-status`, data);
}

//编辑 
export async function updateExamQuestionApi(data: {
  id: Number,
  [key: string]: any
}) {
  return requestClient.patch('/certification/update-exam-questions', data);
}

//导入
export async function uploadExamQuestionsApi(data: any) {
  return requestClient.post('/certification/upload-exam-questions', data, {
    headers: {
      'Content-Type': 'multipart/form-data',
    },
  });
}
